OpenGL supports per-window double buffering using the glXSwapBuffers call. A side effect of calling glXSwapBuffers on a window that the calling thread is currently bound to is that further rendering to the window will not execute until the buffer swap completes. Double buffer hardware usually times the buffer swap to occur during vertical retrace. The glXSwapBuffers may return before the buffer swap completes, but the OpenGL implementation is then responsible for delaying any further OpenGL rendering to the window until the buffer swap actually occurs.